package com.xm.dao.impl;

import com.xm.dao.OrderSettlementsDao;
import com.xm.po.OrderSettlements;
import com.xm.util.DButil;

import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.util.List;

/**
 * @author Administrator
 * @date 2020-08-07-15:32
 * @description 订单结算数据操作接口实现类
 */
public class OrderSettlementsDaoImpl implements OrderSettlementsDao {
    @Override
    public boolean add(OrderSettlements orderSettlements) {
        return DButil.insert(orderSettlements);
    }

    @Override
    public boolean update(OrderSettlements orderSettlements) {
        return DButil.update(orderSettlements);
    }

    @Override
    public OrderSettlements getOrderSettlementsByOrderId(Integer orderId) {
        Connection conn =DButil.getConnection();
        PreparedStatement pstmt=null;
        ResultSet rs=null;
        String sql="";

        return null;
    }

    @Override
    public List<OrderSettlements> getAll() {
        List<OrderSettlements>list= (List<OrderSettlements>) DButil.queryAll(OrderSettlements.class);
        return list;
    }
}
